package com.example.littlepainter.db

import android.graphics.Bitmap
import android.os.Parcelable
import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import kotlinx.android.parcel.Parcelize

@Parcelize
@Entity(tableName = "picture_table")
data class Picture(  //picture_table
    @PrimaryKey(autoGenerate = true)  //主键 自增长
    val pid:Int,
    var name:String,
    var time:String,
    var url: String,
    var thumbnail:Bitmap // Bitmap <-> ByteArray
): Parcelable

